package com.ruoyi.system.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
        import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ruoyi.system.mapper.CamsEnrollInfoMapper;
import com.ruoyi.system.domain.CamsEnrollInfo;
import com.ruoyi.system.service.ICamsEnrollInfoService;

/**
 * 报名信息Service业务层处理
 *
 * @author anskory
 * @date 2024-04-08
 */
@Service
public class CamsEnrollInfoServiceImpl extends ServiceImpl<CamsEnrollInfoMapper, CamsEnrollInfo> implements ICamsEnrollInfoService {
    @Autowired
    private CamsEnrollInfoMapper camsEnrollInfoMapper;


    /**
     * 查询报名信息列表
     *
     * @param camsEnrollInfo 报名信息
     * @return 报名信息
     */
    @Override
    public List<CamsEnrollInfo> selectCamsEnrollInfoList(CamsEnrollInfo camsEnrollInfo) {
        LambdaQueryWrapper<CamsEnrollInfo> lambdaQueryWrapper = new LambdaQueryWrapper<CamsEnrollInfo>();
                    if (camsEnrollInfo.getActivityId() != null  && !camsEnrollInfo.getActivityId().isEmpty())
                    lambdaQueryWrapper.eq(CamsEnrollInfo::getActivityId, camsEnrollInfo.getActivityId());
                    if (camsEnrollInfo.getUsername() != null  )
                    lambdaQueryWrapper.eq(CamsEnrollInfo::getUsername, camsEnrollInfo.getUsername());
                    if (camsEnrollInfo.getEnrollTime() != null  )
                    lambdaQueryWrapper.eq(CamsEnrollInfo::getEnrollTime, camsEnrollInfo.getEnrollTime());
                    if (camsEnrollInfo.getSignInTime() != null  )
                    lambdaQueryWrapper.eq(CamsEnrollInfo::getSignInTime, camsEnrollInfo.getSignInTime());
        return this.list(lambdaQueryWrapper);
    }



}
